package com.codenjoy.tdd;

public class FizzBuzzSolver {

    public static String get(int num) {
        if (num < 1 || num > 33)
        {
            return null;
        }
        boolean containsThree = String.valueOf(num).contains("3");
        if (num % 15 == 0 ){
            return "fizzbuzz";
        } else if ( num%5 ==0 ){
            return "buzz";
        } else if (num%3 ==0 || containsThree){
            return "fizz";
        } else {
            return String.valueOf(num);
        }
    }

}



